-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
added populate aap vars #255
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to fix the ssh_key_data line in the populate_aap/tasks/main.yml
username: user | ||
ssh_key_data: "{{ lookup('file', '/home/user/.ssh/id_rsa') }}" | ||
username: "{{ populate_aap_default_host_user }}" | ||
ssh_key_data: "{{ lookup('file', populate_aap_ssh_key_path) if populate_aap_ssh_key_path is defined else '' }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be just the var {{ populate_aap_ssh_key_path }} and the role should contain all of the non variable information and then this would close the other issue #213
This is a best practice that the defaults should be vars not logic.
username: user | ||
ssh_key_data: "{{ lookup('file', '/home/user/.ssh/id_rsa') }}" | ||
username: "{{ populate_aap_default_host_user }}" | ||
ssh_key_data: "{{ lookup('file', populate_aap_ssh_key_path) if populate_aap_ssh_key_path is defined else '' }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ssh_key_data: "{{ lookup('file', populate_aap_ssh_key_path) if populate_aap_ssh_key_path is defined else '' }}" | |
ssh_key_data: "{{ populate_aap_ssh_key_path }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in addition to above you will need to change the role main task to have the lookup
This Pull Request needs all conversation threads to be resolved. Could you fix it @resoluteCoder? 🙏 |
This Pull Request needs all changes requested to be resolved. Could you fix it @resoluteCoder? 🙏 |
Description
FIXES:
#213
Type of change
What is it?
Checklist